package com.uam.web.common.model;

import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;

import java.util.List;

/**
 * @author uam
 * @create 2023/11/29 21:25
 * @email uam@uam.com
 */
@ApiModel("列表")
@Data
public class PageRes<T> {
    /**
     * 总记录数
     */
    @ApiModelProperty(value = "总记录数")
    private long total;

    /**
     * 列表数据
     */
    @ApiModelProperty(value = "列表数据")
    private List<T> rows;

    public PageRes() {
    }

    public PageRes(List<T> rows, long total) {
        this.rows = rows;
        this.total = total;
    }
}
